/**
 * Created by wzh on 2016/7/5.
 */
swan_pc.config(
    function($stateProvider){
        $stateProvider
            .state('companydetail', {
                parent:'company',
                //'abstract':true,
                url:'/companydetail',
                views:{
                    'companycontent@company':{
                        templateUrl:'scripts/components/myself/company/companyDetail/companyDetail.html',
                        controller:'CompanyDetailController'
                    }
                }
            })
            .state('companycalendar', {
                parent:'companydetail',
                //'abstract':true,
                url:'/calendar',
                views:{
                    'CalOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/calendar/calendarshow/calendarshow.html',
                        controller:'CalShowController'
                    }
                }
            })
            .state('companyaddcalendar', {
                parent:'companydetail',
                //'abstract':true,
                url:'/addcalendar',
                views:{
                    'CalOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/calendar/addclip/addclip.html',
                        controller:'addClipController'
                    }
                }
            })
            .state('companytask', {
                parent:'companydetail',
                //'abstract':true,
                url:'/task',
                views:{
                    'TaskOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/task/tasklistshow/tasklistshow.html',
                        controller:'TaskListController'
                    }
                }
            })
            .state('companyaddtask', {
                parent:'companydetail',
                //'abstract':true,
                url:'/task',
                views:{
                    'TaskOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/task/addtask/addtask.html',
                        controller:'AddTaskController'
                    }
                }
            })
            .state('companycontact', {
                parent:'companydetail',
                //'abstract':true,
                url:'/contact',
                views:{
                    'ContactOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/company/companyDetail/companyContact.html',
                        controller:'CompanyContactController'
                    }
                }
            })
            .state('companycontactdetail', {
                parent:'companydetail',
                //'abstract':true,
                url:'/contactdetail',
                views:{
                    'ContactOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/contact/contactdetail/contactdetail.html',
                        controller:'ContactController'
                    }
                }
            })
            .state('companyaddcontact', {
                parent:'companydetail',
                //'abstract':true,
                url:'/addcontact',
                views:{
                    'ContactOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/contact/addcontact/addcontact.html',
                        controller:'ContactController'
                    }
                }
            })
            .state('companyopp', {
                parent:'companydetail',
                //'abstract':true,
                url:'/opp',
                views:{
                    'OppOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/opportunity/opportunitylist/opportunitylist.html',
                        controller:'OpportunityController'
                    }
                }
            })
            .state('companyoppdetail', {
                parent:'companydetail',
                //'abstract':true,
                url:'/oppdetail',
                views:{
                    'OppOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/opportunity/opportunitydetail/opportunitydetail.html',
                        controller:'OpportunityController'
                    }
                }
            })
            .state('companyaddopp', {
                parent:'companydetail',
                //'abstract':true,
                url:'/addopp',
                views:{
                    'OppOrInput@companydetail':{
                        templateUrl:'scripts/components/myself/opportunity/addopportunity/addopportunity.html',
                        controller:'OpportunityController'
                    }
                }
            })
    })
